home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 March
/
EnigmA AMIGA RUN 05 (1996)(G.R. Edizioni)(IT)[!][issue 1996-03][Skylink CD IV].iso
/
earcd
/
library
/
queue.lzh
/
queue
/
queue_inline.h
< prev
next >
Wrap
C/C++ Source or Header
|
1995-10-12
|
3KB
|
124 lines
#ifndef _INLINE_QUEUE_PROTOTYPES_H
#define _INLINE_QUEUE_PROTOTYPES_H
#include <sys/cdefs.h>
#include <inline/stubs.h>
__BEGIN_DECLS
#ifndef BASE_EXT_DECL
#define BASE_EXT_DECL
#define BASE_EXT_DECL0 extern struct Library *QueueBase;
#endif
#ifndef BASE_PAR_DECL
#define BASE_PAR_DECL
#define BASE_PAR_DECL0 void
#endif
#ifndef BASE_NAME
#define BASE_NAME QueueBase
#endif
BASE_EXT_DECL0
extern void
QAddMsg (BASE_PAR_DECL QHandle qh,QMessage *msg)
{
BASE_EXT_DECL
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
register QMessage *a1 __asm("a1") = msg;
__asm __volatile ("jsr a6@(-0x2a)"
: /* no output */
: "r" (a6), "r" (a0), "r" (a1)
: "a0","a1","d0","d1", "memory");
}
extern ULONG
QClose (BASE_PAR_DECL QHandle qh)
{
BASE_EXT_DECL
register ULONG _res __asm("d0");
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
__asm __volatile ("jsr a6@(-0x24)"
: "=r" (_res)
: "r" (a6), "r" (a0)
: "a0","a1","d0","d1", "memory");
return _res;
}
extern ULONG
QFlush (BASE_PAR_DECL QHandle qh)
{
BASE_EXT_DECL
register ULONG _res __asm("d0");
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
__asm __volatile ("jsr a6@(-0x42)"
: "=r" (_res)
: "r" (a6), "r" (a0)
: "a0","a1","d0","d1", "memory");
return _res;
}
extern QMessage *
QGetMsg (BASE_PAR_DECL QHandle qh)
{
BASE_EXT_DECL
register QMessage * _res __asm("d0");
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
__asm __volatile ("jsr a6@(-0x36)"
: "=r" (_res)
: "r" (a6), "r" (a0)
: "a0","a1","d0","d1", "memory");
return _res;
}
extern QHandle
QOpen (BASE_PAR_DECL STRPTR name,ULONG mode,ULONG sigbit)
{
BASE_EXT_DECL
register QHandle _res __asm("d0");
register struct Library *a6 __asm("a6") = BASE_NAME;
register STRPTR a0 __asm("a0") = name;
register ULONG d0 __asm("d0") = mode;
register ULONG d1 __asm("d1") = sigbit;
__asm __volatile ("jsr a6@(-0x1e)"
: "=r" (_res)
: "r" (a6), "r" (a0), "r" (d0), "r" (d1)
: "a0","a1","d0","d1", "memory");
return _res;
}
extern void
QRemMsg (BASE_PAR_DECL QHandle qh,QMessage *msg)
{
BASE_EXT_DECL
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
register QMessage *a1 __asm("a1") = msg;
__asm __volatile ("jsr a6@(-0x30)"
: /* no output */
: "r" (a6), "r" (a0), "r" (a1)
: "a0","a1","d0","d1", "memory");
}
extern ULONG
QReplyMsg (BASE_PAR_DECL QHandle qh)
{
BASE_EXT_DECL
register ULONG _res __asm("d0");
register struct Library *a6 __asm("a6") = BASE_NAME;
register QHandle a0 __asm("a0") = qh;
__asm __volatile ("jsr a6@(-0x3c)"
: "=r" (_res)
: "r" (a6), "r" (a0)
: "a0","a1","d0","d1", "memory");
return _res;
}
#undef BASE_EXT_DECL
#undef BASE_EXT_DECL0
#undef BASE_PAR_DECL
#undef BASE_PAR_DECL0
#undef BASE_NAME
__END_DECLS
#endif /* _INLINE_QUEUE_PROTOTYPES_H */